<!-- extend base layout -->
{% extends "base.html" %}
{% block css %}
{% endblock %}
{% block content %}
<div class="row">
  <div class="x_panel">
    <div class="x_title">
      <h3>
        <i class="fa fa-folder-open"></i> 
        存储文件
        <small>桌面和模板文件</small>
      </h3>
      <button class="btn btn-tree navbar-right" type="button"  data-placement="top" ><i class="fa fa-tree" style="color:darkgreen"></i></button>
      <ul class="nav navbar-right panel_toolbox">
        <!-- <li><a class="btn-new"><span style="color: #5499c7; "><i class="fa fa-link"></i> Upload from URL</span></a> -->
        <!-- <li><a class="btn-new-local"><span style="color: #5499c7; "><i class="fa fa-plus"></i><i class="fa fa-hdd-o"></i>  Upload from local</span></a></li>-->
      </ul>
      <div class="clearfix"></div>
    </div>
    <div class="x_content">
      <table id="storage" class="table" width="100%">
          <thead>
          <tr>
            <th></th>
            <th>路径</th>
            <th>Id</th>
            <th>格式</th>
            <th>大小</th>
            <th>使用的</th>
            <th>父</th>
            <th>用户</th>
            <th>类型</th>
            <th>域名</th>
            <th>最后</th>
          </tr>
          </thead>
          <tbody>
          </tbody>
      </table>
    </div>
  </div>
</div>
<div class="row">
  <div class="x_panel">
    <div class="x_title">
      <h3><i class="fa fa-times"></i> 删除存储文件 <small>桌面和模板文件已删除</small></h3>
      <ul class="nav navbar-right panel_toolbox">
        <!-- <li><a class="btn-new"><span style="color: #5499c7; "><i class="fa fa-link"></i> Upload from URL</span></a> -->
        <!-- <li><a class="btn-new-local"><span style="color: #5499c7; "><i class="fa fa-plus"></i><i class="fa fa-hdd-o"></i>  Upload from local</span></a></li>-->
      </ul>
      <div class="clearfix"></div>
    </div>
    <div class="x_content">
      <table id="storage_deleted" class="table" width="100%">
          <thead>
          <tr>
            <th>ID</th>
            <th>格式</th>
            <th>大小</th>
            <th>使用</th>
            <th>用户</th>
            <th>类型</th>
            <th>最后</th>
          </tr>
          </thead>
          <tbody>
          </tbody>
      </table>
    </div>

  </div>
</div>
{% if current_user.role == 'admin' %}
<div class="row">
  <div class="x_panel">
    <div class="x_title">
      <h3><i class="fa fa-times"></i> 物理存储文件 <small>从磁盘扫描的未知系统文件</small></h3>
      <ul class="nav navbar-right panel_toolbox">
        <li><a class="btn-phy-update" data-panel="storage_physical"><span style="color: #5499c7; "><i class="fa fa-spinner"></i> 从远程读取</span></a>
      </ul>
      <div class="clearfix"></div>
    </div>
    <div class="x_content">
      <!-- <p class="text-muted font-13 m-b-30"></p>
      <div id="global_actions" width: 15cm;">
         <label class="control-label col-md-3 col-sm-3 col-xs-12 pull-left" for="mactions">
            <h4>
               Global actions:
            </h4>
         </label>
         <div class="col-md-5 col-sm-5 col-xs-12" style="margin-bottom: 20px;">
            <select class="form-control" id="mactions" name="mactions" >
               <option value="none">Select action</option>
               <option value="upgrade_to_storage">Upgrade old disks and domains to new storage table</option>
            </select>
         </div>
      </div> -->
      <table id="storage_physical" class="table" width="100%">
          <thead>
          <tr>
            <th></th>
            <th>路径</th>
            <th>正确链</th>
            <th>大小</th>
            <th>虚拟服务器</th>
            <th>域</th>
            <th>迁移</th>
            <th>选择</th>
          </tr>
          </thead>
          <tbody>
          </tbody>
      </table>
    </div>

  </div>
</div>
{% endif %}
{% include 'admin/pages/storage_modals.html' %}
{% include '/admin/pages/storage_detail.html' %}
{% endblock %}
{% block pagescript %}
    <script src="/isard-admin/static/admin/js/storage.js"></script>
{% endblock %}
